package com.yxj.threadcase1;

public class ThreadDemo9 {
    public static void main(String[] args) {
        /*
        * 需求：某电影院正在上映电影票，共100张，有3个窗口售票，请模拟售票过程*/

        //创建线程对象
        MyThread9 t1 = new MyThread9();
        MyThread9 t2 = new MyThread9();
        MyThread9 t3 = new MyThread9();

        //
        t1.setName("窗口1");
        t2.setName("窗口2");
        t3.setName("窗口3");

        //
        t1.start();
        t2.start();
        t3.start();

    }
}
